package com.sola.jpa.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.sola.jpa.entity.User;
import com.sola.jpa.service.IUserService;

@RestController
@RequestMapping("/jpa/user")

public class JpaUserController {
	
	@Autowired
	IUserService userService;
	
	@RequestMapping("/list")
	public List<User> list (){
		return userService.getAccounts();
	}

}
